package com.guigu.community.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.math.BigDecimal;


@Data
@TableName("procure_details")
public class ProcureDetails {
    @TableId(type = IdType.AUTO)
    @TableField("id")
    private Integer id;

    @TableField("parent_id")
    private Integer parentId;

    @TableField("product_id")
    private String productId;

    private Integer count;

    private BigDecimal price;

    private BigDecimal subtotal;

    // 修改: 添加 @TableField 注解，确保 commodityId 被正确映射到数据库字段
    @TableField("commodity_id")
    private Integer commodityId;
}
